package coreSimulation;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

public class QueueController {

	Queue queue;
	QueueUI queueUI;

	public QueueController(Queue queue, QueueUI queueUI) {
		this.queue = queue;

		this.queueUI = queueUI;
		queueUI.addbuildQueueButtonListener(new BuildQueueController());

	}

	class BuildQueueController implements ActionListener {
		public void actionPerformed(ActionEvent e) {
			Thread thread = new Thread(queue);
			thread.start();

		}
	}

}
